<!doctype html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title>Simple venn.js example</title>
</head>

<body>
    <p> An example providing weights on the importance of each intersection area. This
defines the non-overlapping intersection areas as being unimportant - so that the sets cluster around
set '2' here.
    <div id="weighted_example"></div>
</body>

<script src="https://d3js.org/d3.v4.min.js"></script>
<script src="../venn.js"></script>
<script>
var sets = [{sets: [0], size: 1958},
            {sets: [1], size: 1856},
            {sets: [2], size: 297},
            {sets: [3], size: 17281},
            {sets: [4], size: 4301},
            {sets: [2,0], size: 123},
            {sets: [2,1], size: 139},
            {sets: [2,3], size: 92},
            {sets: [2,4], size: 12},
            {sets: [0,0], size: 0, weight: 1e-10},
            {sets: [0,1], size: 0, weight: 1e-10},
            {sets: [0,3], size: 0, weight: 1e-10},
            {sets: [0,4], size: 0, weight: 1e-10},
            {sets: [1,0], size: 0, weight: 1e-10},
            {sets: [1,1], size: 0, weight: 1e-10},
            {sets: [1,3], size: 0, weight: 1e-10},
            {sets: [1,4], size: 0, weight: 1e-10},
            {sets: [3,0], size: 0, weight: 1e-10},
            {sets: [3,1], size: 0, weight: 1e-10},
            {sets: [3,3], size: 0, weight: 1e-10},
            {sets: [3,4], size: 0, weight: 1e-10},
            {sets: [4,0], size: 0, weight: 1e-10},
            {sets: [4,1], size: 0, weight: 1e-10},
            {sets: [4,3], size: 0, weight: 1e-10},
            {sets: [4,4], size: 0, weight: 1e-10}];


d3.select("#weighted_example").datum(sets).call(venn.VennDiagram())
</script>
</html>
